-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Fixes to resample over DST boundaries #9623
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
The outstanding issue is #9119 which is timezone related, but not DST related. |
@rockg awesome! I listed all of the issues, pls give a check. pls give a release note (listing all of the issues) as well. |
@rockg can you run a perf test (looks like it should be fine, but pls check) |
@rockg I'd like to get this in the 0.16.0 rc, which I am going to do prob tomorrow (0.16. prob 1 week later), can you update? |
Yes, fixing everything up. Should have something in an hour. |
Wow that vbench takes over an hour (and it only works for python 2 which was a nice surprise). There are a few date things in here which surprised me.
|
vbench looks fine, the things that take < 1ms are really hard to time correctly. |
Great news. |
I think this is ok, however, need to check one thing. Can you make a pickle from 0.15.2 and add to the tests, like this: https://github.com/pydata/pandas/blob/master/pandas/tests/test_categorical.py#L2640 (need to test that the DateOffsets survive this change). Basically save say a dict of a couple of examples, pickle it to a file (in 0.15.2), then read in (in the tests) and make sure they compare equal (I think they should), but since adding this attribute, need to make sure. |
The pickle test worked fine. Think we should be good on that front. |
ok looks good will merge in the morning if u have s chance see if anything needs to be updated in the docs about tz (eg in resample section) |
changes to offset classes that weren't working over such boundaries as well as adding normalize() on Timestamp.
merged via dcc68d7 thanks! |
@jreback...thanks. There are a couple travis errors on two of 2.7 jobs with the pickle test (however one of them succeeded). Any thoughts?
|
I rebuilt the pick on 0.15.2 and it works fine. How did you create the pickle? I have only seen this error IIRC if you pickle I think in text mode. |
I thought I used the same recipe as your example. I created a new
virtualenv and saved the pickle with the file in 'wb' mode.
|
Python 2? |
Almost positive (I can confirm tonight). I am positive that I ran the test locally with Python 2.7. Anyways, I'm not sure it's worth more thought right now. Thanks for taking care of it. |
closes #5172
closes #8744
closes #8653
closes #9173
closes #9468
closes #8794
fixes all issues but one attached to #5172. There were several issues as mentioned by my comments in the master list. They are:
normalize_date
does not work with DST change dates as the tz offset is not adjusted.normalize
is added to Timestamp as discussed in ENH: add .normalize() to Timestamp? #8794 (I don't like how this was done, but it seemed the easiest rather than duplicating lots of code intslib.date_normalize
._adjust_dates_anchored
was not localizing properly once times were adjusted.